package com.tjh.gulimall.auth.feign;

import com.tjh.common.utils.R;
import com.tjh.gulimall.auth.vo.SocialUser;
import com.tjh.gulimall.auth.vo.UserLoginVo;
import com.tjh.gulimall.auth.vo.UserRegistVo;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

/**
 * Create by koala on 2021-05-09
 */
@FeignClient("gulimall-member")
public interface MemberFeignService {
    /**
     * day97：用户注册功能
     */
    @PostMapping("/member/member/regist")
    public R regist(@RequestBody UserRegistVo vo);

    /**
     * day98：用户登录
     */
    @PostMapping("/member/member/login")
    public R login(@RequestBody UserLoginVo vo);

    /**
     * day99：社交登录
     */
    @PostMapping("/member/member/oauth2/login")
    public R oauthlogin(@RequestBody SocialUser socialUser) throws Exception;
}
